import 'package:my_blog_flutter/generated/json/base/json_field.dart';
import 'package:my_blog_flutter/generated/json/home_detail_entity.g.dart';
import 'dart:convert';
export 'package:my_blog_flutter/generated/json/home_detail_entity.g.dart';

@JsonSerializable()
class HomeDetailEntity {
	int? code = 0;
	String? message = '';
	HomeDetailData? data;
	int? timestamp = 0;

	HomeDetailEntity();

	factory HomeDetailEntity.fromJson(Map<String, dynamic> json) => $HomeDetailEntityFromJson(json);

	Map<String, dynamic> toJson() => $HomeDetailEntityToJson(this);

	@override
	String toString() {
		return jsonEncode(this);
	}
}

@JsonSerializable()
class HomeDetailData {
	int? id = 0;
	String? title = '';
	String? content = '';
	int? userId = 0;
	int? rateNumber = 0;
	String? createTime = '';
	dynamic updateTime;
	int? state = 0;

	HomeDetailData();

	factory HomeDetailData.fromJson(Map<String, dynamic> json) => $HomeDetailDataFromJson(json);

	Map<String, dynamic> toJson() => $HomeDetailDataToJson(this);

	@override
	String toString() {
		return jsonEncode(this);
	}
}